home *** CD-ROM | disk | FTP | other *** search
/ Aminet 28 / Aminet 28 (1998)(GTI - Schatztruhe)[!][Dec 1998].iso / Aminet / dev / c / qtools0.2-src.lha / src / libqtools / graphics.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-07-13  |  1.2 KB  |  51 lines

  1. #ifndef    GRAPHICS_H
  2. #define    GRAPHICS_H
  3. #include "script.h"
  4.  
  5. /*
  6.  * ============================================================================
  7.  * structures
  8.  * ============================================================================
  9.  */
  10.  
  11. struct palpic {
  12.   char *name;
  13.   short int width, height;
  14.   struct rgb *palette;
  15.   unsigned char rawdata[0];
  16. } __packed;
  17.  
  18. struct rawpic {
  19.   char *name;
  20.   short int width, height;
  21.   struct rgb rawdata[0];
  22. } __packed;
  23.  
  24. struct lump {
  25.   int width, height;
  26.   unsigned char rawdata[0];
  27. } __packed;
  28.  
  29. /*
  30.  * ============================================================================
  31.  * globals
  32.  * ============================================================================
  33.  */
  34.  
  35. extern bool dither;
  36. extern short int dithervalue;
  37. extern bool smoothing;
  38. extern short int smoothingvalue;
  39.  
  40. /*
  41.  * ============================================================================
  42.  * prototypes
  43.  * ============================================================================
  44.  */
  45.  
  46. bool RemapPalettes(unsigned char *dataBody, int dataSize, struct rgb *oldPalette, struct rgb *newPalette);
  47. struct palpic *GetImage(FILE * file, char *picName, short int alignX, short int alignY);
  48. bool PutImage(FILE * file, struct palpic *Picture, filetype picType);
  49.  
  50. #endif
  51.